function[xn]=idft(Xk, N)
    Xk = Xk(:);
    n=0:1:N-1;
    k=0:1:N-1;
    WN = exp(-j*2*pi/N);
    nk=n'*k;
    WNnk=WN.^(-nk);
    xn=(WNnk*Xk)/N;
end